package com.hua.designpattern.creational.factorymethod;

public class Train implements Drivable {

	private int capacity;
	private String trainName = "NO-0";

	@Override
	public void drive() {
		System.out.println(trainName + " is started!!");

	}

	@Override
	public void stop() {
		System.out.println(trainName + " is stopped!!");

	}

	public int getCapacity() {
		return capacity;
	}

	public void setCapacity(int capacity) {
		this.capacity = capacity;
	}

	public String getTrainName() {
		return trainName;
	}

	public void setTrainName(String trainName) {
		this.trainName = trainName;
	}

}
